<?php
namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;

// 聊天日志
class LogRoleChat extends Model
{
    use HasFactory;

    protected $table = "log_role_chat";
    public $timestamps  = false;

    private $prefix = 'log';

    public function setGameArea($serverId) //设置分区
    {
        if(!$serverId) $serverId = '0';
        return parent::setConnection( $this->prefix.'_'. $serverId); // TODO: Change the autogenerated stub
    }

}

